In a conventional Long Term Evolution (LTE) communication network, when there is a communication requirement between two mobile terminals, the communication needs to be forwarded by a base station, and at least a two-hop communication link is required. With the increasing communication requirements, a device to device (Device to Device, D2D) communications technology emerges. The D2D technology allows communication nodes in a short distance to directly communicate with each other without using a base station for forwarding, and a two-hop network is thus changed into a one-hop network, thereby solving the problem of shortage of spectrum resources in a wireless communication system to some extent. The D2D technology can be applied to an Internet of Things communication system such as an Internet of Vehicles communication system. However, in the Internet of Vehicles system, mobile access points are relatively dense, the communication distance between vehicles is relatively short, and the number of communication nodes is relatively large. Existing communication schemes cannot make full use of transmission resources, and often lead to a performance loss and a waste of spectrum resources. Therefore, it is urgent to provide a method to solve the problem.